<?php

declare(strict_types=1);
/**
 * This file is part of Hyperf.
 *
 * @link     https://www.hyperf.io
 * @document https://hyperf.wiki
 * @contact  group@hyperf.io
 * @license  https://github.com/hyperf/hyperf/blob/master/LICENSE
 */
namespace App\Constants;

use Hyperf\Constants\AbstractConstants;
use Hyperf\Constants\Annotation\Constants;

/**
 * 国际化枚举错误信息
 * @package App\Constants
 */
#[Constants]
class ErrorCode extends AbstractConstants
{
    /**
     * @Message("response.success")
     */
    public const SERVER_SUCCESS = 200;

    /**
     * @Message("response.accepted")
     */
    public const SERVER_ACCEPTED = 202;

    /**
     * @Message("response.redirect")
     */
    public const SERVER_REDIRECT = 302;

    /**
     * @Message("response.failed")
     */
    public const SERVER_FAILED = 400;

    /**
     * @Message("response.unauthorized")
     */
    public const SERVER_UNAUTHORIZED = 401;

    /**
     * @Message("response.forbidden")
     */
    public const SERVER_FORBIDDEN = 403;

    /**
     * @Message("response.not_found")
     */
    public const SERVER_NOT_FOUND = 404;

    /**
     * @Message("response.error")
     */
    public const SERVER_ERROR = 500;

    /**
     * @Message("response.rate_limit")
     */
    public const SERVER_RATE_LIMIT = 429;
}
